Package com.cisco.pt.ipc.system.impl
Class TreeNodeImpl
java.lang.Object
com.cisco.pt.ipc.impl.IPCObjectImpl
com.cisco.pt.ipc.system.impl.TreeNodeImpl
Information provided by the PKI file:
\class TreeNode
\brief TreeNode handles and manipulates the activity assessment nodes.
\example appWindow().getActiveFile().getLastAssessedComparatorTree()
- Author:
- Auto-generated
-
Field Summary
Fields inherited from class com.cisco.pt.ipc.impl.IPCObjectImpl
accessMessage, ipcFactory, packetTracerSession -
Constructor Summary
ConstructorsConstructorDescriptionTreeNodeImpl(IPCFactory ipcFactory, PacketTracerSession packetTracerSession, IPCMessageLTV accessMessage) -
Method Summary
Modifier and TypeMethodDescriptionaddChildNode(ComparatorClass classType, String nodeName, String nodeId, String nodeValue, boolean bVariableEnabled) Information provided by the PKI file:intInformation provided by the PKI file:intgetCheckLeafCountByComponent(String component) Information provided by the PKI file:intInformation provided by the PKI file:intgetCheckLeafPointsByComponent(String component) Information provided by the PKI file:Information provided by the PKI file:Information provided by the PKI file:intInformation provided by the PKI file:getChildNodeAt(int index) Information provided by the PKI file:getChildNodeBy(String id) Information provided by the PKI file:Information provided by the PKI file:Information provided by the PKI file:Information provided by the PKI file:Information provided by the PKI file:intInformation provided by the PKI file:intgetLeafCountByComponent(String component) Information provided by the PKI file:Information provided by the PKI file:Information provided by the PKI file:Information provided by the PKI file:Information provided by the PKI file:intInformation provided by the PKI file:intgetTotalLeafPointsByComponent(String component) Information provided by the PKI file:Information provided by the PKI file:Information provided by the PKI file:booleanInformation provided by the PKI file:voidsetCheck(boolean bCheck) Information provided by the PKI file:voidsetIncorrectFeedback(String feedbackStr) Information provided by the PKI file:voidsetNodeName(String name) Information provided by the PKI file:voidsetNodeValue(String value) Information provided by the PKI file:Methods inherited from class com.cisco.pt.ipc.impl.IPCObjectImpl
getAccessMessage, getClassName, getFactory, getObjectUUID, getPacketTracerSession, sendMessage, sendMessageWithReturn, translateToCommandStatusStringPairMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.cisco.pt.ipc.IPCObject
getAccessMessage, getClassName, getFactory, getObjectUUID, getPacketTracerSession
-
Constructor Details
-
TreeNodeImpl
public TreeNodeImpl(IPCFactory ipcFactory, PacketTracerSession packetTracerSession, IPCMessageLTV accessMessage)
-
-
Method Details
-
getNodeId
Information provided by the PKI file:
\brief Returns the ID of this node. \return QString, the ID of this node. -
getNodeName
Information provided by the PKI file:
\brief Returns the name of this node. \return QString, the name of this node.- Specified by:
getNodeNamein interfaceTreeNode- Returns:
- String Returns a String
-
getNodeValue
Information provided by the PKI file:
\brief Returns the value of this node. \return QString, the value of this node.- Specified by:
getNodeValuein interfaceTreeNode- Returns:
- String Returns a String
-
getParentNode
Information provided by the PKI file:
\brief Returns the parent node of this node. \return TreeNode, the TreeNode object of the parent node of this node.- Specified by:
getParentNodein interfaceTreeNode- Returns:
- TreeNode Returns a TreeNode
-
getChildCount
public int getChildCount()Information provided by the PKI file:
\brief Returns the number of child nodes for this node. \return int, the number of child nodes for this node.- Specified by:
getChildCountin interfaceTreeNode- Returns:
- int Returns a int
-
getCheckType
Information provided by the PKI file:
\brief Returns the checktype of this node. \return int, the checktype for this node. Checktypes: eCheckTypeBlank = 0, eCheckTypeHalf = 1, eCheckTypeFull = 2 \remark Full is correct, blank is incorrect, and half means there are correct and incorrect children.- Specified by:
getCheckTypein interfaceTreeNode- Returns:
- ActivityCheckType Returns a ActivityCheckType
-
getChildNodeAt
Information provided by the PKI file:
\brief Returns the child node at the specified index of this node. \param index, the index of the child node of interest. \return TreeNode, the child node at the specified index of this node.- Specified by:
getChildNodeAtin interfaceTreeNode- Parameters:
index- Takes in a parameter of index- Returns:
- TreeNode Returns a TreeNode
-
getChildNodeBy
Information provided by the PKI file:
\brief Returns the child node with the specified ID of this node. \param ID, the ID of the child node of interest. \return TreeNode, the child node with the specified ID of this node.- Specified by:
getChildNodeByin interfaceTreeNode- Parameters:
id- Takes in a parameter of id- Returns:
- TreeNode Returns a TreeNode
-
getCheckOnlyTree
Information provided by the PKI file:
\brief Returns a tree with only half or full checktype nodes. \return TreeNode, the TreeNode object with only half or full checktype nodes.- Specified by:
getCheckOnlyTreein interfaceTreeNode- Returns:
- TreeNode Returns a TreeNode
-
getIncorrectFeedback
Information provided by the PKI file:
\brief Returns the incorrect feedback of this node. \return QString, the incorrect feedback of this node.- Specified by:
getIncorrectFeedbackin interfaceTreeNode- Returns:
- String Returns a String
-
setIncorrectFeedback
Information provided by the PKI file:
\brief Sets the incorrect feedback for this node. \param feedbackStr, the incorrect feedback for this node.- Specified by:
setIncorrectFeedbackin interfaceTreeNode- Parameters:
feedbackStr- Takes in a parameter of feedbackStr
-
getLeafCount
public int getLeafCount()Information provided by the PKI file:
\brief Returns the total number of leaf nodes for this node. \return int, the total number of leaf nodes for this node.- Specified by:
getLeafCountin interfaceTreeNode- Returns:
- int Returns a int
-
getCheckLeafCount
public int getCheckLeafCount()Information provided by the PKI file:
\brief Returns the number of full checktype leaf nodes. \return int, the number of full checktype leaf nodes.- Specified by:
getCheckLeafCountin interfaceTreeNode- Returns:
- int Returns a int
-
getTotalLeafPoints
public int getTotalLeafPoints()Information provided by the PKI file:
\brief Returns the total points of leaf nodes. \return int, the total points of leaf nodes.- Specified by:
getTotalLeafPointsin interfaceTreeNode- Returns:
- int Returns a int
-
isVariableEnabled
public boolean isVariableEnabled()Information provided by the PKI file:
\brief Returns true if this node is variable enabled, otherwise false. \return bool, true if this node is variable enabled, otherwise false.- Specified by:
isVariableEnabledin interfaceTreeNode- Returns:
- boolean Returns a boolean
-
getVariableName
Information provided by the PKI file:
\brief Returns the variable name of this node. \return QString, the variable name of this node.- Specified by:
getVariableNamein interfaceTreeNode- Returns:
- String Returns a String
-
getVariableToString
Information provided by the PKI file:
\brief Returns the variable name if the value type of the node is entire range, otherwise the value of this node. \return QString, the variable name if the value type of the node is entire range, otherwise the value of this node.- Specified by:
getVariableToStringin interfaceTreeNode- Returns:
- String Returns a String
-
setCheck
public void setCheck(boolean bCheck) Information provided by the PKI file:
\brief Checks or unchecks this node. \param bCheck, true to check this node, false to uncheck it. -
getComparatorClass
Information provided by the PKI file:
\brief Returns the comparator class. \return ComparatorClass, the comparator class. eCompClass_Ip = 0, eCompClass_Routing = 1, eCompClass_Acl = 2, eCompClass_Nat = 3, eCompClass_Physical = 4, eCompClass_Switching = 5, eCompClass_Connectivity = 6, eCompClass_Logical = 7, eCompClass_All = 8, eCompClass_Encircling_Head = 9, eCompClass_Encircling_Sub = 10- Specified by:
getComparatorClassin interfaceTreeNode- Returns:
- ComparatorClass Returns a ComparatorClass
-
setNodeName
Information provided by the PKI file:
\brief Sets the node of this node. \param name, the node of this node.- Specified by:
setNodeNamein interfaceTreeNode- Parameters:
name- Takes in a parameter of name
-
setNodeValue
Information provided by the PKI file:
\brief Sets the value of this node. \param value, the value of this node.- Specified by:
setNodeValuein interfaceTreeNode- Parameters:
value- Takes in a parameter of value
-
getLeafCountByComponent
Information provided by the PKI file:
\brief Returns the number of leaves with the specified component name (includes all children). \param component, the name of the component of interest. \return int, the number of leaves with the specified component name (includes all children).- Specified by:
getLeafCountByComponentin interfaceTreeNode- Parameters:
component- Takes in a parameter of component- Returns:
- int Returns a int
-
getCheckLeafCountByComponent
Information provided by the PKI file:
\brief Returns the number of checked leaves with the specified component name (including all children). \param component, the name of the component of interest. \return int, the number of checked leaves with the specified component name (including all children).- Specified by:
getCheckLeafCountByComponentin interfaceTreeNode- Parameters:
component- Takes in a parameter of component- Returns:
- int Returns a int
-
getCheckLeafPointsByComponent
Information provided by the PKI file:
\brief Returns the total points of checked leaves with the specified component name (including all children). \param component, the name of the component of interest. \return int, the total points of checked leaves with the specified component name (including all children).- Specified by:
getCheckLeafPointsByComponentin interfaceTreeNode- Parameters:
component- Takes in a parameter of component- Returns:
- int Returns a int
-
getTotalLeafPointsByComponent
Information provided by the PKI file:
\brief Returns the total points of leaves with the specified component name (including all children). \param component, the name of the component of interest. \return int, the total points of leaves with the specified component name (including all children).- Specified by:
getTotalLeafPointsByComponentin interfaceTreeNode- Parameters:
component- Takes in a parameter of component- Returns:
- int Returns a int
-
getCheckLeafPoints
public int getCheckLeafPoints()Information provided by the PKI file:
\brief Returns the total points of all nodes that have checks, including all children. \return int, the total points of all nodes that have checks, including all children.- Specified by:
getCheckLeafPointsin interfaceTreeNode- Returns:
- int Returns a int
-
getCompPointPair
Information provided by the PKI file:
\brief Returns the component and points as a pair associated with only this node. There can be many components and points per node. \return pair<QString, QString>, the list of comma-separated components and list of comma-separated points.- Specified by:
getCompPointPairin interfaceTreeNode- Returns:
- Pair<String, String> Returns a Pair<String, String>
-
getChildNodeByFullId
Information provided by the PKI file:
\brief Returns the child node with the specified full ID of this node. \param ID, the full ID of the child node of interest. \return TreeNode, the child node with the specified full ID of this node.- Specified by:
getChildNodeByFullIdin interfaceTreeNode- Parameters:
id- Takes in a parameter of id- Returns:
- TreeNode Returns a TreeNode
-
addChildNode
public TreeNode addChildNode(ComparatorClass classType, String nodeName, String nodeId, String nodeValue, boolean bVariableEnabled) Information provided by the PKI file:
\brief Create a new child node and add it to the tree \param classType, ComparatorClass eCompClass_Ip = 0, eCompClass_Routing = 1, eCompClass_Acl = 2, eCompClass_Nat = 3, eCompClass_Physical = 4, eCompClass_Switching = 5, eCompClass_Connectivity = 6, eCompClass_Logical = 7, eCompClass_All = 8, eCompClass_Encircling_Head = 9, eCompClass_Encircling_Sub = 10 \param nodeName, the name of the node. \param nodeId, the id of the node. \param nodeValue, the value of the node. \param bVariableEnabled, bool-true if variable is enabled and false if it's not on this node \return TreeNode, the child node that was newly created- Specified by:
addChildNodein interfaceTreeNode- Parameters:
classType- Takes in a parameter of classTypenodeName- Takes in a parameter of nodeNamenodeId- Takes in a parameter of nodeIdnodeValue- Takes in a parameter of nodeValuebVariableEnabled- Takes in a parameter of bVariableEnabled- Returns:
- TreeNode Returns a TreeNode
-